﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using SQLServerDAL;

using System.Data;
using DataAnalyseTool.Model;
using DataAnalyseTool.Repository;
namespace DataAnalyseTool.BusinessTier.Bll
{
  public class UserBLL
  {
    UserDal ud = null;
    public UserBLL()
    {
      ud = new UserDal();
    }
    public  int AddUser(Users user)
    {
      //UserDal ud = new UserDal();
      return ud.AddUser(user);
    }
    public  int DeleteUser(string userid)
    {
      return ud.DeleteUser(userid);
    }
    public  int UpdateUser(Users user)
    {
      return ud.UpdateUser(user);
    }
    public  DataTable GetAllUser()
    {
      return ud.GetAllUser();
    }

    public  DataTable LoginUser(string username, string password)
    {
      return ud.GetUser(username, password);

    }
    public  int GetUser(string username)
    {
      return ud.GetUser(username);
    }
    public  DataTable GetUser(string username, string password)
    {
      return ud.GetUser(username, password);
    }
    public  DataTable GetUserByName(string username)
    {
      return ud.GetUserByName(username);
    }
  }
}
